<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
	<title>AlphaAdmin</title>
	<link rel="stylesheet" type="text/css" href="../../assets/css/bootstrap.min.css">
	<link rel="stylesheet" type="text/css" href="../../assets/css/bootstrap-table.min.css">
	<link rel="stylesheet" type="text/css" href="../../assets/css/iconfont.css">
	<link rel="stylesheet" type="text/css" href="../../assets/css/style.css">
	<script type="text/javascript" charset="utf-8" src="../../utf8-jsp/ueditor.config.js"></script>
	<script type="text/javascript" charset="utf-8" src="../../utf8-jsp/ueditor.all.min.js"> </script>
	<!--建议手动加在语言，避免在ie下有时因为加载语言失败导致编辑器加载失败-->
	<!--这里加载的语言文件会覆盖你在配置项目里添加的语言类型，比如你在配置项目里配置的是英文，这里加载的中文，那最后就是中文-->
	<script type="text/javascript" charset="utf-8" src="../../utf8-jsp/lang/zh-cn/zh-cn.js"></script>

</head>
<body>
	<div class="skin-default" id="wrapper">
		<header class="navbar-header">
			<div class="brand">
				<a class="navbar-brand" href="index.html" title="AlphaAdmin">报名系统后台管理</a>
			</div>
			<!--导航栏-->
			<div class="navbar">
				<i class="sidebar-toggle iconfont icon-menu" data-toggle="push-menu" role="button">
				</i>
				<div class="navbar-menu pull-right">
					<ul class="nav navbar-nav">
						<li class="dropdown message">
							<a class="dropdown-toggle" data-toggle="dropdown" href="#" title="消息">
								<i class="iconfont icon-email"></i>
								<span class="badge">4</span>
							</a>
							<ul class="dropdown-menu">
								<li class="header">
									您有4条消息
								</li>
								<li class="body">
									<ul class="menu">
										<li>
											<a href="#" title="如何设置头部head...">
												<div class="pull-left">
													<img class="img-circle" src="../../assets/avatars/avatars.png">
												</div>
												<h4 class="name">
													匿名用户
													<small class="pull-right">
														<i class="iconfont icon-time"></i>
														5分钟前
													</small>
												</h4>
												<p class="content">
													如何设置头部head的meta值
												</p>
											</a>
										</li>
										<li>
											<a href="#" title="如何设置头部head...">
												<div class="pull-left">
													<img class="img-circle" src="../../assets/avatars/avatars.png">
												</div>
												<h4 class="name">
													匿名用户
													<small class="pull-right">
														<i class="iconfont icon-time"></i>
														5分钟前
													</small>
												</h4>
												<p class="content">
													如何设置头部head的meta值
												</p>
											</a>
										</li>
										<li>
											<a href="#" title="如何设置头部head...">
												<div class="pull-left">
													<img class="img-circle" src="../../assets/avatars/avatars.png">
												</div>
												<h4 class="name">
													匿名用户
													<small class="pull-right">
														<i class="iconfont icon-time"></i>
														5分钟前
													</small>
												</h4>
												<p class="content">
													如何设置头部head的meta值
												</p>
											</a>
										</li>
										<li>
											<a href="#" title="如何设置头部head...">
												<div class="pull-left">
													<img class="img-circle" src="../../assets/avatars/avatars.png">
												</div>
												<h4 class="name">
													匿名用户
													<small class="pull-right">
														<i class="iconfont icon-time"></i>
														5分钟前
													</small>
												</h4>
												<p class="content">
													如何设置头部head的meta值
												</p>
											</a>
										</li>
									</ul>
								</li>
								<li class="footer">
									<a href="#" title="查看所有消息">
										查看所有消息
									</a>
								</li>
							</ul>
						</li>
						<li class="dropdown notify">
							<a class="dropdown-toggle" data-toggle="dropdown" href="#" title="通知">
								<i class="iconfont icon-bells"></i>
								<span class="badge">7</span>
							</a>
							<ul class="dropdown-menu">
								<li class="header">
									您有7个通知
								</li>
								<li class="body">
									<ul class="menu">
										<li>
											<a class="text-danger" href="#" title="系统发生一个未知错误">
												<i class="iconfont icon-error pull-left"></i>
												<p class="content">发生一个系统路径错误</p>
											</a>
										</li>
										<li>
											<a class="text-warning" href="#" title="系统发出一个警告">
												<i class="iconfont icon-alert pull-left"></i>
												<p class="content">为安全起见,请删除install文件夹</p>
											</a>
										</li>
										<li>
											<a class="text-success" href="#" title="修改成功">
												<i class="iconfont icon-ok pull-left"></i>
												<p class="content">您更新了个人资料</p>
											</a>
										</li>
										<li>
											<a class="text-info" href="#" title="新成员">
												<i class="iconfont icon-menu-user pull-left"></i>
												<p class="content">3位新成员</p>
											</a>
										</li>
										<li>
											<a class="text-muted" href="#" title="点赞">
												<i class="iconfont icon-thumbs-up pull-left"></i>
												<p class="content">5个点赞</p>
											</a>
										</li>
									</ul>
								</li>
								<li class="footer">
									<a href="#" title="查看所有通知">
										查看所有通知
									</a>
								</li>
							</ul>
						</li>
						<li class="dropdown user">
							<a class="dropdown-toggle" data-toggle="dropdown" href="#" title="用户">AlphaAdmin</a>
							<ul class="dropdown-menu">
								<li>
									<a data-toggle="modal" data-target=".menu-setpassword" href="#" title="个人信息">
										<i class="iconfont icon-menu-user"></i>
										修改密码
									</a>
								</li>
								<li>
									<a href="#" title="系统设置">
										<i class="iconfont icon-setting"></i>
										系统设置
									</a>
								</li>
								<li class="divider"></li>
								<li>
									<a data-toggle="modal" data-target=".menu-logout" href="#" title="登出">
										<i class="iconfont icon-power"></i>
										登出
									</a>
								</li>
							</ul>
						</li>
					</ul>
				</div>
			</div>
		</header>
		<!-- 左侧导航 -->
		<aside class="main-sidebar">
			<div class="user-panel">
				<div class="image pull-left">
					<!--双向绑定用户的头像-->
					<img src="../../assets/avatars/avatars.png" alt="">
				</div>
				<div class="info pull-right">
					<!--双向绑定一个用户名和昵称-->
					<p class="title">admin</p>
					<strong>超级管理员</strong>
				</div>
			</div>
			<section class="sidebar">
				<ul class="sidebar-menu" data-widget="tree">
					<li class="active">
						<a href="../../index.html" title="仪表盘">
							<i class="iconfont icon-dashborad"></i>
							<small>首页</small>
						</a>
					</li>
					<li class="treeview">
						<a href="#" title="考试管理">
							<i class="iconfont icon-chart"></i>
							<small>考试管理</small>
							<span class=" pull-right">
								<i class="iconfont icon-menu-left-small"></i>
							</span>
						</a>
						<ul class="treeview-menu">
							<li>
								<a href="../../pages/examination/addNewExam.html">
									<i class="iconfont icon-circle-hollow"></i>
									<small>添加考试</small>
								</a>
							</li>
							<li>
								<a href="../../pages/examination/manageExam.html">
									<i class="iconfont icon-circle-hollow"></i>
									<small>管理考试</small>
								</a>
							</li>
						</ul>
					</li>
					<li class="treeview">
						<a href="#" title="考生管理">
							<i class="iconfont icon-form"></i>
							<small>考生管理</small>
							<span class=" pull-right">
								<i class="iconfont icon-menu-left-small"></i>
							</span>
						</a>
						<ul class="treeview-menu">
							<li>
								<a href="../../pages/examinee/addNewStudent.html">
									<i class="iconfont icon-circle-hollow"></i>
									<small>添加考生</small>
								</a>
							</li>
							<li>
								<a href="../../pages/examinee/manageStudent.html">
									<i class="iconfont icon-circle-hollow"></i>
									<small>考生信息</small>
								</a>
							</li>

						</ul>
					</li>
					<li class="treeview">
						<a href="#" title="公告管理">
							<i class="iconfont icon-components"></i>
							<small>公告管理</small>
							<span class=" pull-right">
								<i class="iconfont icon-menu-left-small"></i>
							</span>
						</a>
						<ul class="treeview-menu">
							<li>
								<a href="../../pages/annManagement/addNewAnn.html">
									<i class="iconfont icon-circle-hollow"></i>
									<small>添加公告</small>
								</a>
							</li>
							<li>
								<a href="../../pages/annManagement/manageAnn.html">
									<i class="iconfont icon-circle-hollow"></i>
									<small>管理公告</small>
								</a>
							</li>

						</ul>
					</li>
					<li class="treeview">
						<a href="#">
							<i class="iconfont icon-table"></i>
							<small>首页轮播图</small>
							<span class=" pull-right">
								<i class="iconfont icon-menu-left-small"></i>
							</span>
						</a>
						<ul class="treeview-menu">
							<li>
								<a href="">
									<i class="iconfont icon-circle-hollow"></i>
									<small>修改轮播图</small>
								</a>
							</li>

						</ul>
					</li>

				</ul>
			</section>
		</aside>
		<!--内容模版-->
		<div class="page-wrapper">
			<el-breadcrumb separator-class="el-icon-arrow-right">
				<el-breadcrumb-item :to="{ path: '/' }">首页></el-breadcrumb-item>
				<el-breadcrumb-item>公告管理></el-breadcrumb-item>
				<el-breadcrumb-item>添加新公告</el-breadcrumb-item>
			</el-breadcrumb>

			<div>
				<h1>完整demo</h1>
				<script id="editor" type="text/plain" style="width:1024px;height:500px;"></script>
			</div>
			<div id="btns">
				<div>
					<button onclick="getAllHtml()">获得整个html的内容</button>
					<button onclick="getContent()">获得内容</button>
					<button onclick="setContent()">写入内容</button>
					<button onclick="setContent(true)">追加内容</button>
					<button onclick="getContentTxt()">获得纯文本</button>
					<button onclick="getPlainTxt()">获得带格式的纯文本</button>
					<button onclick="hasContent()">判断是否有内容</button>
					<button onclick="setFocus()">使编辑器获得焦点</button>
					<button onmousedown="isFocus(event)">编辑器是否获得焦点</button>
					<button onmousedown="setblur(event)" >编辑器失去焦点</button>

				</div>
				<div>
					<button onclick="getText()">获得当前选中的文本</button>
					<button onclick="insertHtml()">插入给定的内容</button>
					<button id="enable" onclick="setEnabled()">可以编辑</button>
					<button onclick="setDisabled()">不可编辑</button>
					<button onclick=" UE.getEditor('editor').setHide()">隐藏编辑器</button>
					<button onclick=" UE.getEditor('editor').setShow()">显示编辑器</button>
					<button onclick=" UE.getEditor('editor').setHeight(300)">设置高度为300默认关闭了自动长高</button>
				</div>

				<div>
					<button onclick="getLocalData()" >获取草稿箱内容</button>
					<button onclick="clearLocalData()" >清空草稿箱</button>
				</div>

			</div>
			<div>
				<button onclick="createEditor()">
					创建编辑器</button>
				<button onclick="deleteEditor()">
					删除编辑器</button>
			</div>

		</div>
		<!-- 修改密码模态框 -->
		<div class="modal fade menu-setpassword" tabindex="-1" role="dialog">
			<div class="modal-dialog modal-sm" role="document">
				<div class="modal-content">
					<div class="modal-header">
						<button type="button" class="close" data-dismiss="modal" aria-label="Close">
							<span aria-hidden="true">&times;</span>
						</button>
						<h4 class="modal-title">修改密码</h4>
					</div>
					<div class="modal-body">
						<table class="table">
							<tbody>
								<tr>
									<th>
										旧密码
									</th>
									<td>
										<input type="text" class="form-control" placeholder="请输入旧密码" name="js-oldPassword">
									</td>
								</tr>
								<tr>
									<th>
										新密码
									</th>
									<td>
										<input type="text" class="form-control" placeholder="请输入新密码" name="js-newPassword">
									</td>
								</tr>
								<tr>
									<th>
										确认密码
									</th>
									<td>
										<input type="text" class="form-control" placeholder="请再次输入新密码" name="js-verifyPassword">
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<div class="modal-footer">
						<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
	                    <button type="button" class="btn btn-primary">保存</button>
					</div>
				</div>
			</div>
		</div>
		<!-- 退出提示模态框 -->
		<div class="modal fade menu-logout" tabindex="-1" role="dialog">
			<div class="modal-dialog modal-sm" role="document">
				<div class="modal-content">
					<div class="modal-header">
						<button type="button" class="close" data-dismiss="modal" aria-label="Close">
							<span aria-hidden="true">&times;</span>
						</button>
						<h4 class="modal-title">提示</h4>
					</div>
					<div class="modal-body">
						<p>是否确定退出</p>
					</div>
					<div class="modal-footer">
						<button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
	                    <button type="button" class="btn btn-primary">登出</button>
					</div>
				</div>
			</div>
		</div>
	</div>
	<script type="text/javascript" src="../../assets/js/jquery-2.1.0.min.js"></script>
	<script type="text/javascript" src="../../assets/js/jquery-ui.min.js"></script>
	<script type="text/javascript" src="../../assets/js/bootstrap.min.js"></script>
	<script type="text/javascript" src="../../assets/libs/tinymce/tinymce.min.js"></script>
	<script type="text/javascript" src="../../assets/js/Chart.min.js"></script>
	<script type="text/javascript" src="../../assets/js/echarts.min.js"></script>
	<script type="text/javascript" src="../../assets/js/alpha.js"></script>
	<script type="text/javascript" src="../../assets/js/dashboard.js"></script>
<style>
.copyrights{text-indent:-9999px;height:0;line-height:0;font-size:0;overflow:hidden;}
</style>
<div class="copyrights" id="links20210126">
	Collect from <a href="http://www.cssmoban.com/"  title="网站模板">模板之家</a>
	<a href="https://www.chazidian.com/"  title="查字典">查字典</a>
</div>
	<script type="text/javascript">

		//实例化编辑器
		//建议使用工厂方法getEditor创建和引用编辑器实例，如果在某个闭包下引用该编辑器，直接调用UE.getEditor('editor')就能拿到相关的实例
		var ue = UE.getEditor('editor');


		function isFocus(e){
			alert(UE.getEditor('editor').isFocus());
			UE.dom.domUtils.preventDefault(e)
		}
		function setblur(e){
			UE.getEditor('editor').blur();
			UE.dom.domUtils.preventDefault(e)
		}
		function insertHtml() {
			var value = prompt('插入html代码', '');
			UE.getEditor('editor').execCommand('insertHtml', value)
		}
		function createEditor() {
			enableBtn();
			UE.getEditor('editor');
		}
		function getAllHtml() {
			alert(UE.getEditor('editor').getAllHtml())
		}
		function getContent() {
			var arr = [];
			arr.push("使用editor.getContent()方法可以获得编辑器的内容");
			arr.push("内容为：");
			arr.push(UE.getEditor('editor').getContent());
			alert(arr.join("\n"));
		}
		function getPlainTxt() {
			var arr = [];
			arr.push("使用editor.getPlainTxt()方法可以获得编辑器的带格式的纯文本内容");
			arr.push("内容为：");
			arr.push(UE.getEditor('editor').getPlainTxt());
			alert(arr.join('\n'))
		}
		function setContent(isAppendTo) {
			var arr = [];
			arr.push("使用editor.setContent('欢迎使用ueditor')方法可以设置编辑器的内容");
			UE.getEditor('editor').setContent('欢迎使用ueditor', isAppendTo);
			alert(arr.join("\n"));
		}
		function setDisabled() {
			UE.getEditor('editor').setDisabled('fullscreen');
			disableBtn("enable");
		}

		function setEnabled() {
			UE.getEditor('editor').setEnabled();
			enableBtn();
		}

		function getText() {
			//当你点击按钮时编辑区域已经失去了焦点，如果直接用getText将不会得到内容，所以要在选回来，然后取得内容
			var range = UE.getEditor('editor').selection.getRange();
			range.select();
			var txt = UE.getEditor('editor').selection.getText();
			alert(txt)
		}

		function getContentTxt() {
			var arr = [];
			arr.push("使用editor.getContentTxt()方法可以获得编辑器的纯文本内容");
			arr.push("编辑器的纯文本内容为：");
			arr.push(UE.getEditor('editor').getContentTxt());
			alert(arr.join("\n"));
		}
		function hasContent() {
			var arr = [];
			arr.push("使用editor.hasContents()方法判断编辑器里是否有内容");
			arr.push("判断结果为：");
			arr.push(UE.getEditor('editor').hasContents());
			alert(arr.join("\n"));
		}
		function setFocus() {
			UE.getEditor('editor').focus();
		}
		function deleteEditor() {
			disableBtn();
			UE.getEditor('editor').destroy();
		}
		function disableBtn(str) {
			var div = document.getElementById('btns');
			var btns = UE.dom.domUtils.getElementsByTagName(div, "button");
			for (var i = 0, btn; btn = btns[i++];) {
				if (btn.id == str) {
					UE.dom.domUtils.removeAttributes(btn, ["disabled"]);
				} else {
					btn.setAttribute("disabled", "true");
				}
			}
		}
		function enableBtn() {
			var div = document.getElementById('btns');
			var btns = UE.dom.domUtils.getElementsByTagName(div, "button");
			for (var i = 0, btn; btn = btns[i++];) {
				UE.dom.domUtils.removeAttributes(btn, ["disabled"]);
			}
		}

		function getLocalData () {
			alert(UE.getEditor('editor').execCommand( "getlocaldata" ));
		}

		function clearLocalData () {
			UE.getEditor('editor').execCommand( "clearlocaldata" );
			alert("已清空草稿箱")
		}
	</script>
</body>
</html>